package com.lzy.shops.mapper;

import com.lzy.shops.bean.GoodsCart;
import com.lzy.shops.bean.Search;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface GoodsCartMapper {
    public List<GoodsCart> findAll(@Param("userId") Integer userId,@Param("search") Search search);
    public Integer addGoodsCar(@Param("shopId") Integer shopId,
                               @Param("nums") Integer nums,
                               @Param("userId") Integer userId);
    public Integer findByGoodsCarNums(@Param("shopId") Integer shopId,@Param("userId") Integer userId);
    public GoodsCart findByGoodsCar(@Param("carId") Integer carId,@Param("userId") Integer userId);
    public Integer updateGoodsCarNums(@Param("id") Integer id,@Param("num") Integer num);
    public Integer findAllCount(@Param("userId") Integer userId);
    public Integer deleteGoodsCar(@Param("userId") Integer userId,@Param("carId") Integer carId);
}
